<?php

use yii\helpers\Html;


$this->title = sprintf("%s的机票、地接酒店、游览(岸上游)信息",$product->name);

?>
<div class="product-flight-index">

    <h2 class="page-header"><span style="font-size: 18px;"><?= Html::encode($this->title) ?></span>
        <p class="pull-right">
            <?= Html::a(Yii::t('app', 'Create'), ['create','product_id'=>$product->id], ['class' => 'btn btn-success']) ?>
        </p>
    </h2>
    
    <h4>机票</h4>
    <table class="table table-striped table-bordered">
           <thead>
               <tr>
                    <th>名称</th>
                    <th>数量</th>
                    <th>价格</th>
                    <th>备注说明</th>
                    <th>状态</th>
                    <th>操作</th>
               </tr>
           </thead>  
           <tbody>
               <?php if(!empty($flight)){?>
                    <?php foreach($flight as $val){?>
                          <tr>
                              <td><?=$val->name?></td> 
                              <td><?=$val->num?></td>
                              <td><?=$val->price?></td>
                              <td><?=$val->remark?></td>
                              <td><?=\Yii::$app->params['status'][$val->status]?></td> 
                              <td><?=Html::a('<i class="glyphicon glyphicon-eye-open"></i>',['flight-view','id'=>$val->id],['title' => '查看', 'target'=>'_blank']);?>
                                  <?=Html::a('<i class="glyphicon glyphicon-pencil"></i>',['flight-update','id'=>$val->id],['title' => '更新', 'target'=>'_blank']); ?>
                              </td> 
                          </tr>  
                    <?php }?>   
               <?php }else{?>
                    <tr><td colspan="6"><div class="empty">没有找到数据。</div></td></tr>
               <?php }?>
           </tbody>
    </table>

    <h4>地接酒店</h4>
    <table class="table table-striped table-bordered">
           <thead>
               <tr>
                    <th>名称</th>
                    <th>数量</th>
                    <th>价格</th>
                    <th>备注说明</th>
                    <th>状态</th>
                    <th>操作</th>
               </tr>
           </thead>  
           <tbody>
               <?php if(!empty($group)){?>
                    <?php foreach($group as $val){?>
                          <tr>
                              <td><?=$val->name?></td> 
                              <td><?=$val->num?></td>
                              <td><?=$val->price?></td>
                              <td><?=$val->remark?></td>
                              <td><?=\Yii::$app->params['status'][$val->status]?></td> 
                              <td><?=Html::a('<i class="glyphicon glyphicon-eye-open"></i>',['group-view','id'=>$val->id],['title' => '查看', 'target'=>'_blank']);?>
                                  <?=Html::a('<i class="glyphicon glyphicon-pencil"></i>',['group-update','id'=>$val->id],['title' => '更新', 'target'=>'_blank']); ?>
                              </td> 
                          </tr>  
                    <?php }?>   
               <?php }else{?>
                    <tr><td colspan="6"><div class="empty">没有找到数据。</div></td></tr>
               <?php }?>
           </tbody>
    </table>

    <h4>岸上游</h4>
    <table class="table table-striped table-bordered">
           <thead>
               <tr>
                    <th>名称</th>
                    <th>数量</th>
                    <th>价格</th>
                    <th>备注说明</th>
                    <th>状态</th>
                    <th>操作</th>
               </tr>
           </thead>  
           <tbody>
               <?php if(!empty($visit)){?>
                    <?php foreach($visit as $val){?>
                          <tr>
                              <td><?=$val->name?></td> 
                              <td><?=$val->num?></td>
                              <td><?=$val->price?></td>
                              <td><?=$val->remark?></td>
                              <td><?=\Yii::$app->params['status'][$val->status]?></td> 
                              <td><?=Html::a('<i class="glyphicon glyphicon-eye-open"></i>',['visit-view','id'=>$val->id],['title' => '查看', 'target'=>'_blank']);?>
                                  <?=Html::a('<i class="glyphicon glyphicon-pencil"></i>',['visit-update','id'=>$val->id],['title' => '更新', 'target'=>'_blank']); ?>
                              </td> 
                          </tr>  
                    <?php }?>   
               <?php }else{?>
                    <tr><td colspan="6"><div class="empty">没有找到数据。</div></td></tr>
               <?php }?>
           </tbody>
    </table>

</div>
